package com.cskaoyan.mapper;

import com.cskaoyan.bean.*;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface OrderMapper {
    long countByExample(OrderExample example);

    int deleteByExample(OrderExample example);

    int deleteByPrimaryKey(Integer id);

    int insert(Order record);

    int insertSelective(Order record);

    List<Order> selectByExample(OrderExample example);

    Order selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("record") Order record, @Param("example") OrderExample example);

    int updateByExample(@Param("record") Order record, @Param("example") OrderExample example);

    int updateByPrimaryKeySelective(Order record);

    int updateByPrimaryKey(Order record);

    List<GoodsRows> statOrderGoods();

    List<OrderRows> statOrder();

    List<WxOrderListVO> selectOrdersByUserId(@Param("sort") String sort, @Param("order") String order, @Param("id") Integer id, @Param("showType") Integer showType);

    WxOrderDetailBean queryWxOrderDetail(Integer orderId);

    int wxCancelOrder(Integer orderId);

    List<WxOrderGoods> queryWxOrderGoodsDetail(Integer orderId);

    int wxDeleteOrder(Integer orderId);

    int wxDeleteOrderGppds(Integer orderId);

    WxOrderGoods queryWxOrderGoodsByOrderIdAndGoodsId(@Param("orderId") Integer orderId, @Param("goodsId") Integer goodsId);

    Integer selectGoodsIdByPrimaryKey(Integer orderGoodsId);

    int queryOrderGoodsByOrderId(Integer orderId);

}